package cn.jy.erp.domain;

import java.io.Serializable;

/**
 * 系统权限管理
 */
public class Permission implements Serializable {
	private Long id;
	private String sn;//编号 xxx:yyy

	private String name;// 权限名称
	private String resource;// 资源地址,url地址
	// 额外增加的字段
	private Integer state = 0;// 状态:0:正常(默认),-1:禁用

	public Permission() {

	}

	public Permission(String name, String resource) {
		this.name = name;
		this.resource = resource;
	}

	public Long getId() {
		return id;
	}

	public void setId(Long id) {
		this.id = id;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getResource() {
		return resource;
	}

	public void setResource(String resource) {
		this.resource = resource;
	}

	public Integer getState() {
		return state;
	}

	public void setState(Integer state) {
		this.state = state;
	}

	public String getSn() {
		return sn;
	}

	public void setSn(String sn) {
		this.sn = sn;
	}

	@Override
	public String toString() {
		return "Permission [id=" + id + ", sn=" + sn + ", name=" + name
				+ ", resource=" + resource + ", state=" + state + "]";
	}

	
}
